home *** CD-ROM | disk | FTP | other *** search
-
-
-
- CCCCUUUUTTTT((((1111)))) UUUUNNNNIIIIXXXX 4444....0000 CCCCUUUUTTTT((((1111))))
-
-
-
- NNNNAAAAMMMMEEEE
- paste - merge same lines of several files or subsequent
- lines of one file
-
- SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
- ppppaaaasssstttteeee ffffiiiilllleeee1111 ffffiiiilllleeee2222 ............
- ppppaaaasssstttteeee ----ddddlllliiiisssstttt ffffiiiilllleeee1111 ffffiiiilllleeee2222 ............
- ppppaaaasssstttteeee ----ssss [[[[----dddd]]]]lllliiiisssstttt ffffiiiilllleeee1111 ffffiiiilllleeee2222 ............
-
- DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
- In the first two forms, _p_a_s_t_e concatenates corresponding
- lines of the given input files _f_i_l_e_1, _f_i_l_e_2, etc. It treats
- each file as a column or columns of a table and pastes them
- together horizontally (parallel merging). If you will, it
- is the counterpart of _c_a_t(1) which concatenates vertically,
- i.e., one file after the other. In the last form above,
- _p_a_s_t_e replaces the function of an older command with the
- same name by combining subsequent lines of the input file
- (serial merging). In all cases, lines are glued together
- with the _t_a_b character, or with characters from an
- optionally specified _l_i_s_t. Output is to the standard
- output, so it can be used as the start of a pipe, or as a
- filter, if ---- is used in place of a file name.
-
- The meanings of the options are:
-
- ----dddd
- Without this option, the new-line characters of each but
- the last file (or last line in case of the ----ssss option) are
- replaced by a _t_a_b character. This option allows replacing
- the _t_a_b character by one or more alternate characters (see
- below).
-
- _l_i_s_t
- One or more characters immediately following ----dddd replace the
- default _t_a_b as the line concatenation character. The list
- is used circularly, i.e., when exhausted, it is reused. In
- parallel merging (i.e., no ----ssss option) the lines from the
- last file are always terminated with a new-line character,
- not from the _l_i_s_t. The list may contain the special escape
- sequences: \\\\nnnn (new-line), \\\\tttt (tab), \\\\\\\\ (backslash), and \\\\0000
- (empty string, not a null character.) Quoting may be
- necessary, if characters have special meaning to the shell
- (e.g., to get one backslash, use -_d"\\\\"). SPECIAL NOTE:
- This version of _p_a_s_t_e has had the list of special
- characters expanded from the Unix(Tm) standard to include
- the following additional characters: \\\\bbbb (backspace), \\\\ffff
- (form-feed), \\\\rrrr (carriage return), \\\\vvvv (vertical tab).
-
- ----ssss
- Merge subsequent lines rather than one from each input
- file. Use _t_a_b for concatenation, unless a _l_i_s_t is
-
-
-
- Page 1 (printed 8/19/84)
-
-
-
-
-
-
- CCCCUUUUTTTT((((1111)))) UUUUNNNNIIIIXXXX 4444....0000 CCCCUUUUTTTT((((1111))))
-
-
-
- specified with ----dddd option. Regardless of the _l_i_s_t, the very
- last character of the file is forced to be a new-line.
-
- ----
- May be used in place of any file name, to read a line from
- the standard input. (There is no prompting).
-
- EEEEXXXXAAAAMMMMPPPPLLLLEEEESSSS
- ls | paste -d
- list directory in one column
-
- ls | paste - - - -
- list directory in four columns
-
- SSSSEEEEEEEE AAAALLLLSSSSOOOO
- grep(1),paste(1).
-
- DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
- _n_o _d_e_l_i_m_i_t_e_r_s
- Missing _l_i_s_t for ----dddd option
-
- <_f_i_l_e_n_a_m_e> : _c_a_n_n_o_t _o_p_e_n
- _p_a_s_t_e was given a bad filename
-
- _t_o_o _m_a_n_y _f_i_l_e_s
- Except for ----ssss option, no more than 12 input files may be
- specified.
-
- CCCCAAAAVVVVEEEEAAAATTTTSSSS
- This program is a complete rewrite of the Bell Laboratories
- command of the same name; no part of the original source or
- manual is included. Therefore, you may feel free to use it,
- and its source, without violation of any contract
- agreements. However, I retain the copyright in order to
- specify it remain available for use by all and sundry,
- without cost. Feel free to modify as necessary, although I
- went to great pains to recreate the behavior of the original
- command; I would suggest this congruence be maintained.
-
- Along the same lines, although I've made a reasonable effort
- to test the more arcane behavior of the original _p_a_s_t_e and
- reproduce it, there are no guarantees; and there _a_r_e four
- known differences between the original program and
- documentation, and this version. All are downward
- compatible. First, _p_a_s_t_e as distributed with Unix has a bug
- in the way it handles multiple files for the ----ssss option.
- This has been fixed, and the bug reported to the providers
- of the Unix command. Secondly, the list of valid escape
- characters for the _l_i_s_t has been expanded. Third, the 511
- character/line restriction has been removed. Finally,
- extant undocumented diagnostics have been added to the man
- page, and the one pertaining to the (now obsolete) _l_i_n_e _t_o_o
-
-
-
- Page 2 (printed 8/19/84)
-
-
-
-
-
-
- CCCCUUUUTTTT((((1111)))) UUUUNNNNIIIIXXXX 4444....0000 CCCCUUUUTTTT((((1111))))
-
-
-
- _l_o_n_g removed.
-
- I remain in no way liable for any loss, either explicit or
- incidental, that may be incurred through use of this
- command. I do ask that any bugs (and, hopefully, fixes) be
- reported back to me as encountered. - David M. Ihnat,
- ihuxx!ignatz
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Page 3 (printed 8/19/84)
-
-
-